let walletException = {};

walletException.handlerException = (error) => {
    error = error.info.error;
    if (error.code === 4001) {
        return Promise.reject(new Error("用户取消"));
    } else if (error.code === -32603) {
        let errMsg = error.data.message;
        return Promise.reject(new Error(errMsg));
    }
}

export default walletException;
